package com.hsteach.enums;

import com.hsteach.common.exception.ServiceException;
import lombok.AllArgsConstructor;
import lombok.Getter;

import java.util.Arrays;

/**
 * <p>
 *
 * </p>
 *
 * @author mgb
 * @version BaseConfigEnum, java v1.0 2023-11-21 18:51 EXP $
 */
@Getter
@AllArgsConstructor
public enum BaseConfigEnum {
    BASE_SCORE("BASE_SCORE", "基本分数"),
    EVALUATE_SCORE("EVALUATE_SCORE", "评分周期设置");

    private String  name;
    private String desc;

    public static BaseConfigEnum getInByCode(String name){
        BaseConfigEnum baseConfigEnum = Arrays.stream(BaseConfigEnum.values()).filter(e -> e.getName().equals(name)).findFirst().orElse(null);
        return baseConfigEnum;
    }


}
